<%@ page import="java.text.DecimalFormat" %>
<%@ page import="org.apmap.base.OfferType" %>
<%@ page import="org.apmap.base.Office" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="/WEB-INF/tags/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/tags/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/tags/struts-logic.tld" prefix="logic" %>
<%
    DecimalFormat decimalFormat = new DecimalFormat("#.##");
    Office office = (Office) request.getAttribute("office");
%>
<form action="#" style="font-family:Arial;font-size:10px" id="flatForm">
    <input type="hidden" name="flatid" value="<%=office.getId()%>" readonly="readonly"/>
    тип <b><%=office.getType() == OfferType.RENT ? "аренда" : "продажа"%></b>
    адрес <b><%=office.getAddress()%></b>
    <br/>

    комнаты <b><%=office.getRoomNumber()%></b>&nbsp;
    цена <b><%=decimalFormat.format(office.getPrice())%>&nbsp;<%=office.getCurrency().toShortString()%></b>
    <br/>

    площадь <b><%=office.getSquare()%></b>&nbsp;
    этаж <b><%=office.getFloor()%></b>
    <br/>

    комментарии<br/>
    <textarea name="CM" rows="5" width="100%" readonly="readonly" style="font-family:Arial;font-size:10px"><%=office.getComment()%></textarea>
</form>
